package org.arpit.tutorial.shapes;

import javafx.application.Application;
import javafx.geometry.Insets;
import javafx.scene.Scene;
import javafx.scene.control.Label;
import javafx.scene.layout.VBox;
import javafx.scene.shape.QuadCurve;
import javafx.stage.Stage;

public class QuadCurveDemo extends Application{
	public static void main(String[] args) {
		Application.launch(args);
	}

	@Override
	public void start(Stage primaryStage) {
		primaryStage.setTitle("Shapes Demo");
		VBox vbox = new VBox();
		vbox.setPadding(new Insets(10));
		vbox.setSpacing(10);
		vbox.setStyle("-fx-border-color:blue");
		Scene scene = new Scene(vbox, 600, 600);
		
		//--------------------------------------------------------------------------
		Label label = new Label("Shapes Demo");
		
		QuadCurve quad = new QuadCurve();
		quad.setStartX(0.0f);
		quad.setStartY(50.0f);
		quad.setEndX(50.0f);
		quad.setEndY(50.0f);
		quad.setControlX(25.0f);
		quad.setControlY(0.0f);
		
		vbox.getChildren().addAll(label, quad);
		
		//--------------------------------------------------------------------------
		
		primaryStage.setScene(scene);
		primaryStage.show();
	}

}
